//
//  userio.hpp --- user Input/Output
//

#include "strng.hpp"

#define LN_PER_PAGE  23

void enableCancel(BOOL flag);
void enableRandomizer( BOOL flag );
void makeRandoms( int howMany );
extern LNUM getRandom();
extern int  GetMenuChoice(void);
extern BOOL PromptUserNumber( char far *prompt, LNUM& aNum);
extern BOOL GetUserInt( int& aNum, int nDigits=4);
extern BOOL GetUserString( char * aStr, int maxChars );
extern BOOL GetUserString( String& aStr, int maxChars );
extern BOOL GetUserFloat( float& aNum);
extern BOOL UserCancelled();
extern int  GetYN(BOOL, BOOL echo=TRUE);
extern void AnyKeyToContinue(void);
extern void AnyKeyToReturn(void);
extern BOOL showHelpFile( char far *pFileName, BOOL ynFlag=TRUE,
                          int nLines=LN_PER_PAGE );
extern int  selectColor( int& fgColor, int& bgColor );

extern void setColor( int fgColor, int bgColor );

// External Functions:
extern "C" int sort_function( const void *a, const void *b);

#ifdef USE_WINDOWS
// Dummy calls to support windows env. for testing
void        _Cdecl textbackground( int __newcolor );
void        _Cdecl textcolor( int __newcolor );
#endif
